package cn.xxm.ff.log.config;

import cn.xxm.ff.log.common.utils.PropertyUtil;
import org.springframework.boot.autoconfigure.condition.ConditionalOnWebApplication;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.core.env.ConfigurableEnvironment;

import javax.annotation.Resource;

/**
 * @author xxm
 * @create 2019-11-02 22:43
 */
@Configuration
@ConditionalOnWebApplication  // WEB应用才生效
public class LogDesensitionAutoConfiguration {


    @Resource
    private ConfigurableEnvironment env;

    @Bean
    public PropertyUtil propertyUtil() {
        return new PropertyUtil(env);
    }

}
